class A:
    pass


class B(A):
    pass


class C(B):
    pass

c_c = C()
b_b = B()
print(isinstance(c_c, A))
print(isinstance(b_b, C))